Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove superseeded conditional branch instructions #805

Merged
merged 7 commits into from
Nov 25, 2023

Conversation

Robbepop
Copy link
Member

Closes #800.

@paritytech-cicd-pr
Copy link

paritytech-cicd-pr commented Nov 25, 2023

BENCHMARKS

NATIVEWASMTIME
BENCHMARKMASTERPRDIFFMASTERPRDIFFWASMTIME OVERHEAD
execute/
br_table
1.49ms 1.53ms 🔴 2.84% 1.28ms 1.27ms ⚪ -0.88% 🟢 -17%
execute/
call/host/1
36.96µs 36.15µs 🟢 -2.99% 39.36µs 39.83µs 🔴 1.20% 🟢 10%
execute/
call/rec
169.79µs 166.50µs 🟢 -2.02% 338.81µs 351.92µs 🔴 3.89% 🔴 111%
execute/
count_until
7.40ms 7.48ms ⚪ 0.91% 7.50ms 7.63ms 🔴 1.66% 🟢 2%
execute/
factorial/iter
328.28µs 344.06µs 🔴 4.62% 298.71µs 308.79µs 🔴 3.42% 🟢 -10%
execute/
factorial/rec
779.81µs 737.44µs 🟢 -5.48% 1.32ms 1.28ms 🟢 -2.97% 🟡 73%
execute/
fibonacci/iter
1.35ms 1.36ms ⚪ 0.96% 1.27ms 1.27ms ⚪ -0.08% 🟢 -7%
execute/
fibonacci/rec
6.82ms 6.68ms 🟢 -2.29% 13.15ms 12.92ms 🟢 -1.65% 🟡 93%
execute/
fibonacci/tail
1.44ms 1.67ms 🔴 16.27% 3.59ms 3.81ms 🔴 6.32% 🔴 128%
execute/
fuse
7.31ms 8.16ms 🔴 11.26% 12.44ms 12.58ms ⚪ 1.12% 🟡 54%
execute/
global/bump
1.50ms 1.32ms ⚪ -7.77% 1.51ms 1.60ms 🔴 5.98% 🟢 21%
execute/
global/get_const
730.83µs 685.19µs 🟢 -6.71% 747.36µs 743.91µs ⚪ -0.43% 🟢 9%
execute/
is_even/rec
1.09ms 1.07ms ⚪ -1.09% 2.14ms 2.22ms 🔴 3.48% 🔴 107%
execute/
memory/fill_bytes
1.13ms 1.14ms 🔴 1.51% 1.24ms 1.23ms ⚪ -0.86% 🟢 8%
execute/
memory/sum_bytes
1.01ms 1.06ms 🔴 6.00% 1.21ms 1.23ms 🔴 1.41% 🟢 16%
execute/
memory/vec_add
2.94ms 2.95ms ⚪ 0.04% 3.48ms 3.56ms 🔴 2.23% 🟢 20%
execute/
recursive_scan
199.67µs 184.76µs 🟢 -5.34% 362.35µs 370.95µs 🔴 2.28% 🔴 101%
execute/
recursive_trap
16.37µs 15.33µs 🟢 -6.30% 32.94µs 34.58µs 🔴 5.15% 🔴 126%
execute/
regex_redux
606.37µs 599.16µs ⚪ -0.56% 998.71µs 1.03ms 🔴 3.50% 🟡 72%
execute/
rev_complement
441.81µs 444.11µs ⚪ 0.66% 619.98µs 631.62µs 🔴 1.86% 🟢 42%
execute/
tiny_keccak
349.86µs 351.30µs ⚪ 0.56% 365.60µs 382.43µs 🔴 4.67% 🟢 9%
execute/
trunc_f2i
599.34µs 618.72µs 🔴 3.25% 886.25µs 949.45µs 🔴 7.14% 🟡 53%
instantiate/
wasm_kernel
53.60µs 54.85µs ⚪ 0.93% 57.06µs 53.38µs 🟢 -7.72% 🟢 -3%
overhead/
call/typed/0
1.22ms 1.24ms ⚪ 4.95% 851.48µs 861.88µs 🔴 1.30% 🟢 -30%
overhead/
call/typed/16
1.62ms 1.62ms ⚪ 0.37% 1.92ms 2.04ms 🔴 6.62% 🟢 26%
overhead/
call/untyped/0
1.77ms 1.68ms 🟢 -5.75% 1.28ms 1.34ms 🔴 4.59% 🟢 -20%
overhead/
call/untyped/16
2.48ms 2.49ms ⚪ 0.47% 3.73ms 3.80ms 🔴 2.10% 🟡 53%
translate/
bz2
1.33ms 1.33ms ⚪ -0.14% 2.43ms 2.44ms ⚪ -0.21% 🟡 84%
translate/
erc1155
279.01µs 279.34µs ⚪ -0.07% 472.79µs 473.16µs ⚪ -0.19% 🟡 69%
translate/
erc20
135.38µs 136.82µs ⚪ 1.26% 226.36µs 225.63µs ⚪ -0.25% 🟡 65%
translate/
erc721
191.83µs 192.22µs ⚪ 0.05% 326.77µs 325.84µs ⚪ -0.14% 🟡 70%
translate/
pulldown_cmark
3.66ms 3.66ms ⚪ 0.42% 6.40ms 6.50ms ⚪ 1.28% 🟡 77%
translate/
spidermonkey
0.00ns 0.00ns ⚪ 0.46% 0.00ns 0.00ns ⚪ -0.86% 🟢 0%
translate/
wasm_kernel
4.89ms 4.92ms ⚪ 0.86% 8.59ms 8.66ms ⚪ 0.74% 🟡 76%

Link to pipeline

@codecov-commenter
Copy link

codecov-commenter commented Nov 25, 2023

Codecov Report

Attention: 60 lines in your changes are missing coverage. Please review.

Comparison is base (13dd961) 81.00% compared to head (80c466d) 80.93%.

Files Patch % Lines
...wasmi/src/engine/regmach/executor/instrs/branch.rs 46.15% 42 Missing ⚠️
...smi/src/engine/regmach/translator/instr_encoder.rs 44.82% 16 Missing ⚠️
crates/wasmi/src/engine/regmach/bytecode/utils.rs 77.77% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #805      +/-   ##
==========================================
- Coverage   81.00%   80.93%   -0.08%     
==========================================
  Files         274      274              
  Lines       25319    25364      +45     
==========================================
+ Hits        20510    20528      +18     
- Misses       4809     4836      +27     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Robbepop Robbepop merged commit 834c3fb into master Nov 25, 2023
13 checks passed
@Robbepop Robbepop deleted the rf-remove-duplicated-br-instrs branch November 25, 2023 10:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Try to remove Instruction::branch_{i32,i64}_{nez,eqz}
3 participants